<template>
	<div class="contentBox margin_top">
		<div class="flexbetween mainpadding15 F5F8FA">
			<div class="flexleft">
				<div class="text_b color_six margin_right3">{{child.paytime_text}}</div>
				<div class="text_b color_six margin_right3">订单号：{{child.order_no}}</div>
				<div class="text_b color_six">{{child.teacher.username}}</div>
			</div>
			<div class="text_b color_theme" v-show="child.state==5">待评价</div>
			<div class="text_b color_theme" v-show="child.state==6">已完成</div>
		</div>
		<div class=" mainpadding15 flexleft">
			<!-- 只有优课有图片 -->
			<img class="imgBox margin_right2" :src="child.image_text" alt="" v-if="child.image_text">
			<div class="flexbetween flex1">
				<div class="heightText justify_between_column" style="width: 220px;">
					<div class="text_dt color_three lianghang">{{child.lesson_name}}</div>
					<div class="flexleft margin_top1">
						<div class="vipBox margin_right1" v-if="child.is_vip==1">VIP</div>
						<div class="num">编号：{{child.id}}</div>
					</div>
				</div>
				<div class="text_d color_red">￥{{child.pay_price}}</div>
				<div class="" v-if="!types">
					<div class="themeBtnBg" v-show="child.state==5" @click="goEvaluateOrder(child.id)">立即评价</div>
					<!-- <div class="themeBtnBg">立即考试</div> -->
					<div class="flexcenter margin_top1">
						<!-- <div class="text_b color_nine textcenter" v-show="child.state==6" @click="goEvaluateOrder()">评价</div> -->
						<!-- <div class="line margin_left1 margin_right1" v-show="child.state==6"></div> -->
						<div class="text_b color_nine textcenter pointer" @click="goInfo(child.id)">详情</div>
					</div>
				</div>
			</div>
		</div>
	</div>
</template>

<script>
	export default{
		props:{
			child:{
				type:Object,
				default:()=>{
					return {}
				}
			},
			types:{
				type:Number,
				default:()=>{
					return ""
				}
			}
		},
		data(){
			return {
				
			}
		},
		methods:{
			goEvaluateOrder(id){ //立即评价
				this.$router.push({
					path:"/evaluateOrder",
					query:{
						id
					}
				})
			},
			goInfo(id){
				this.$router.push({
					path:"/mine/studyOrderInfo",
					query:{
						id
					}
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.contentBox{
		/* // width: 741px; */
		/* // height: 149px; */
		background: #FFFFFF;
		border-radius: 4px 4px 4px 4px;
		border: 1px solid #EAEAEA;
	}
	.imgBox{
		width: 126px;
		height: 74px;
		border-radius: 4px 4px 4px 4px;
	}
	.heightText{
		height: 74px;
	}
	.vipBox {
		padding: 5px 10px;
		background: rgba(255, 0, 0, .1);
		border-radius: 6px 6px 6px 6px;
		font-size: 12px;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #FF0000;
	}
	
	.num {
		padding: 5px 10px;
		background: rgba(153, 153, 153, .1);
		border-radius: 6px 6px 6px 6px;
		font-size: 12px;
		font-family: PingFang SC-Medium, PingFang SC;
		font-weight: 500;
		color: #999999;
	}
	.line{
		width: 0;
		height: 10px;
		border: 1px solid #E9E9E9;
	}
</style>